import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

public class Solution1431 {
    public List<Boolean> kidsWithCandies(int[] candies, int extraCandies) {
        List<Boolean> ans=new ArrayList<>();
        int max= Arrays.stream(candies).max().getAsInt();
        for (int candy : candies) {
            ans.add(candy+extraCandies>=max);
        }
        return ans;
    }

    public static void main(String[] args) {
        System.out.println(new Solution1431().kidsWithCandies(new int[]{2,3,5,1,3},3));
    }
}
